Learn R Programming

Rfast (version 1.5)

Transpose of a matrix: Transpose of a matrix

Description

Transpose of a matrix.

Usage

transpose(x)

Arguments

x
A numerical square matrix with data.

Value

The transposed matrix.

References

Gilbert Strang (2006). Linear Algebra and its Applications (4th edition).

See Also

nth, colMaxs, colMins, colrange

Examples

Run this code
x <- matrix( rnorm(500 * 500), ncol = 500, nrow=500 )
system.time( transpose(x) )
system.time( t(x)  )

Run the code above in your browser using DataLab